home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Windows News 2010 Summer - Disc 1
/
WN_Ete2010_CD1.iso
/
Onglet5
/
Weezo
/
Weezo setup.exe
/
{code_appDir}
/
www
/
local
/
newVersion.php
< prev
next >
Wrap
PHP Script
|
2010-05-19
|
3KB
|
85 lines
<?php
/**
* New weezo version available message box
*
*
*
* PHP version 5
*
* LICENSE: This source file is subject to version 3.0 of the PHP license
* that is available through the world-wide-web at the following URI:
* http://www.php.net/license/3_0.txt. If you did not receive a copy of
* the PHP License and are unable to obtain it through the web, please
* send a note to license@php.net so we can mail you a copy immediately.
*
* @category NA
* @package NA
* @author Nicolas Bruley / Peer 2 World <contact@weezo.net>
* @copyright 2005-2009 Nicolas Bruley / Peer 2 World
* @license http://www.php.net/license/3_0.txt PHP License 3.0
* @version CVS: $Id:$
* @link http://www.weezo.net
* @since File available since Release 1.0.0
*/
// Initialize script data
require_once('localFunctions.php');
lfInit();
/**
* Save preferences
*/
if(isset($_POST['savePrefs']) && ($_POST['savePrefs']=='auto' || $_POST['savePrefs']=='disabled')){
cfServerSendCommand('changeParameter name="updateApplication" value="'.$_POST['savePrefs'].'"');
}
// Udate disabled : quit
if(cfGGetVar('updateApplication')=='disabled'){
cfInsertHEAD(false);
echo '</head><body onload="wl.UICommand(\'close\')"></body>';
exit;
}
// Set default value if not already set
if(!cfGGetVar('updateApplication')) cfGSetVar('updateApplication','confirm');
cfInsertHEAD(false);
echo '<meta width="440x175"></meta>';
echo '<meta wintitle="Weezo"></meta>';
echo '</head>';
echo '<body oncontextmenu="return false;" onSelect="document.deselForm.desel.select();">';
echo outDivFrame('frame2',false,'margin-top:10px');
echo outImage(outIcon('installIcon'),false,false,'float:left; margin-right:1em');
echo cfCaption('newVersionAvailable');
echo '<br/><br/>'.cfCaption('newVersionDownload');
echo '<form name="dontAskForm" method="POST" action="">';
// Save / Cancel buttons
echo '<div style="position:relative; top:-4px; text-align:center; width:100%">'.outButton(cfCaption('genOK'),'javascript:dl();',outIcon('ok'));
echo '<span style="padding-left:2em;"></span>'.outButton(cfCaption('genCancel'),'javascript:savePrefs();',outIcon('cancel'));
echo '</div></div>';
echo '<input type="hidden" name="savePrefs" style="display:none;" />';
echo '<input type="checkbox" name="dontAsk" style="margin-top:3px; margin-right:1em;" /><span>'.cfCaption('dontAskAnymore').'</span>';
echo '</form>';
if(isset($_GET['dlAdress'])) $adress=$_GET['dlAdress']; else $adress=DNS_SITE.'/download.php';
$adress.="?lng=".cfGGetVar('language');
?>
<script type="text/javascript" language="javascript">
function dl(){
W.open("<?php echo $adress; ?>");
wl.UICommand('close');
}
function doCancel(){
if(!dgn("dontAsk").checked) wl.UICommand('close');
else {
dgn("savePrefs").value="disabled";
D.dontAskForm.submit();
}
}
</script>
</body></html>